package com.gitee.lichoking.mysoap.convert;

import com.gitee.lichoking.mysoap.util.StringUtils;
import org.dom4j.Node;

import java.math.BigInteger;

/**
 * BigInteger转化器
 *
 * @author lich
 * @date 2021/6/1
 */
public class BigInterConverter implements Converter<BigInteger> {
    @Override
    public BigInteger nodeTextToJavaData(Node node) {
        String text = node.getText();
        if (StringUtils.isEmpty(text)) {
            return null;
        }
        return new BigInteger(text);
    }
}